import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { PriceCalendarVO, PriceCalendarQuery, PriceCalendarDTO } from '@/api/hotel/priceCalendar/types';

/**
 * 查询酒店日历价格列表
 * @param query
 * @returns {*}
 */

export const listPriceCalendar = (query?: PriceCalendarQuery): AxiosPromise<PriceCalendarVO[]> => {
  return request({
    url: '/hotel/priceCalendar/wechat',
    method: 'get',
    params: query
  });
};

export const inventoryModify = (dto: PriceCalendarDTO) => {
  return request({
    url: '/hotel/priceCalendar/inventoryModify',
    method: 'post',
    data: dto
  });
};
